package demo1;

import java.util.InputMismatchException;
import java.util.Scanner;

public class Test {
    public static void main(String[] args) {
        int sum;
        Scanner scanner = new Scanner(System.in);
        int a = scanner.nextInt();
        try{
            int b = scanner.nextInt();
            sum = a / b;
            System.out.println(sum);
            sum = a + b;
            System.out.println(sum);
            sum = a - b;
            System.out.println(sum);
            sum = a * b;
            System.out.println(sum);
            if(b == 0){
                System.out.println("除数为零，错误");
            }
        }catch(InputMismatchException e){
            System.out.println("输入错误");
        }catch(Exception e){
            System.out.println("发生未知错误");
        }finally {
            scanner.close();
        }
    }
}
